﻿using Bentley.CIMChina.CIMRoadsCLR;
using Bentley.ECObjects.Instance;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace CheccCoverplateCulvertAssemble
{
    public class Class1
    {
        public static void Test()
        {
            
            DepthMap depthMap = new DepthMap();
            Viewport viewPort = Session.GetActiveViewport();
            DgnModelRef acteveModelRef = Session.Instance.GetActiveDgnModelRef();
            StatusInt errorDetails;
            ModelId modelId = Session.Instance.GetActiveDgnFile().FindModelIdByName("没有标题的设计");
            DgnModel sourceModel = Session.Instance.GetActiveDgnFile().LoadRootModelById(out errorDetails, modelId);
            if (0 != depthMap.DrapeAndSimplfy(viewPort, sourceModel, acteveModelRef, 5, 0))
            {
                return;
            }

            //if (0 != depthMap.GatherData(viewPort, eAgenda, strokeTolerance, false))
            //{
            //    return;
            //}
        }
    }
}
